]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
Fix details pane repositioning
authorSiegfried-Angel Gevatter Pujals <rainct@ubuntu.com>
Fri, 31 Jul 2009 14:08:39 +0000 (16:08 +0200)
committerSiegfried-Angel Gevatter Pujals <rainct@ubuntu.com>
Fri, 31 Jul 2009 14:12:19 +0000 (16:12 +0200)
Two calls to _repositionDetails() were done too early,
before the visibility of the results pane had changed,
so they had no effect. Thus when a search was done while
a details pane was active, the pane with the results was
hidden by the details pane.

In addition to fixing this, move the two remaining calls to
the line after changing the results pane's visibility
to make it clearer why the calls are there.

js/ui/overlay.js

index 2741040c3d0bbe2be9553663909c494bc595eb25..b2156af47119fa28715e0147a1179253d0452614 100644 (file)
@@ -583,9 +583,9 @@ Dash.prototype = {
         this._resultsAppsSection.display.show();
         this._resultsPane.append(this._resultsAppsSection.actor, Big.BoxPackFlags.EXPAND);
         this._resultsPane.show();
+        this._repositionDetails();
 
         this._moreAppsLink.setText("Less...");
-        this._repositionDetails();
         this.emit('panes-displayed');
     },
 
@@ -617,11 +617,10 @@ Dash.prototype = {
         this._resultsDocsSection.display.show();
         this._resultsPane.append(this._resultsDocsSection.actor, Big.BoxPackFlags.EXPAND);
         this._resultsPane.show();
+        this._repositionDetails();
 
         this._moreDocsLink.setText("Less...");
 
-        this._repositionDetails();
-
         this.emit('panes-displayed');
     },
 
@@ -642,7 +641,6 @@ Dash.prototype = {
     },
 
     _setSearchMode: function() {
-        this._repositionDetails();
 
         if (this._resultsShowing())
             return;
@@ -656,17 +654,18 @@ Dash.prototype = {
         this._resultsPane.append(this._resultsDocsSection.actor, Big.BoxPackFlags.EXPAND);
 
         this._resultsPane.show();
+        this._repositionDetails();
 
         this.emit('panes-displayed');
     },
 
     _unsetSearchMode: function() {
-        this._repositionDetails();
 
         if (this._moreDocsMode || this._moreAppsMode || !this._resultsShowing())
             return;
 
         this._resultsPane.hide();
+        this._repositionDetails();
 
         this._resultsPane.remove_actor(this._resultsAppsSection.actor);
         this._resultsAppsSection.display.hide();